/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package koala.objects;

import java.util.ArrayList;

/**
 *
 * @author Desktop
 */
public class ProjectLeader extends User{
    
   public ProjectLeader(){
       super();
   }
   
   public ProjectLeader(String userId, byte[] password, String name,ArrayList<Project> projects, boolean status){
       super(userId, password,name,projects,status);
   }
   static ArrayList<User> addMembers(ArrayList<User> userlist, int numOfMembers){
       ArrayList<User> projectMembers = new ArrayList<>();
       
       do{
           
           
           Object user = null;
           projectMembers.add(checkList(userlist,(User)user));
       }while(projectMembers.size() < numOfMembers);
       return projectMembers;
   }
    
   static void setProjectComplete(Project project){
         project.setStatus(false);
    }
   
   static User checkList(ArrayList<User> userlist, User name){
        if(userlist.contains(name)){
            return (ProjectLeader)userlist.get(userlist.indexOf(name));
        } else {
            return null;
   } 
   }
    //code for uploading file sa User nalang ilagay extends nmn eh. xD
    
}
